﻿using System;

namespace program06
{
    class Program
    {
        static void Main(string[] args)
        {
            decimal totaPrice = 0M;
            Console.WriteLine("请选择打折方式（1.原价，2.打9折，3.打八折,4.满两百减十块）：");
            var type = Console.ReadLine();

            CashStrategy cs;
            switch (type)
            {
                case "1":
                    cs = new CashStrategy("Normal");
                    totaPrice += cs.GetTotal(100);
                    break;

                case "2":
                    cs = new CashStrategy("Rebate", 0.9);
                    totaPrice += cs.GetTotal(100);
                    break;

                case "3":
                    cs = new CashStrategy("Rebate", 0.8);
                    totaPrice += cs.GetTotal(100);
                    break;

                case "4":
                    cs = new CashStrategy("Return", 1, 200M, 10M);
                    totaPrice += cs.GetTotal(300);
                    break;


                default:
                    break;
            }
            Console.WriteLine("原价:300，应付:" + totaPrice);
        }
    }
}
